package com.ruoyi.io;

import java.io.Serializable;             // 引入 Serializable 接口
public class Person implements Serializable{
    String name;
    int age;

    public Person(String name, int age) {
        this.name = name;
        this.age = age;
    }

    public String toString() {
        return "姓名：" + name + "\n年龄：" + age;
    }
}

